//
//  CDRecDetailController.swift
//  CDLiftWithDisplay
//
//  Created by SteveLi on 2017/9/18.
//  Copyright © 2017年 李军桦. All rights reserved.
//

import UIKit

class CDRecDetailController: UIViewController {

    @IBOutlet weak var detailImageView: UIImageView!
    
    @IBOutlet weak var introView: UITextView!
    var recommendModel:CDRecommendModel?
    
    override func viewDidLoad() {
        super.viewDidLoad()
        //设置辩题
        title = "推荐详情"
        //控制器中，一般使用前一个控制器传入的值时
        detailImageView.image = UIImage(named: recommendModel?.detailImage ?? "")
        //设置详细说明文字
        if let filePath = Bundle.main.path(forAuxiliaryExecutable: recommendModel?.intro ?? ""),let textStr = try? String(contentsOfFile: filePath){
            //赋值
            introView.text = textStr
        }
        
       
    }


    


}
